
<?php

	$con=new mysqli("localhost","root","","blog") or die("<p>connect failed</P>");
	$con->set_charset("utf8");
	$table=$con->query("select * from usr");

?>



<!DOCTYPE HTML>
<html lang="zh-CN">
<head>
<meta charset="UTF-8">
<title>关于站长</title>
<meta name="keywords" content="个人博客" />
<meta name="description" content="" />
		<script type="text/javascript" src="../js/jquery-3.2.1.min.js"></script>
		<!-- 最新版本的 Bootstrap 核心 CSS 文件 -->
		<link rel="stylesheet" href="https://cdn.bootcss.com/bootstrap/3.3.7/css/bootstrap.min.css" integrity="sha384-BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u" crossorigin="anonymous">
		   
		<!-- 可选的 Bootstrap 主题文件（一般不用引入） -->
		<link rel="stylesheet" href="https://cdn.bootcss.com/bootstrap/3.3.7/css/bootstrap-theme.min.css" integrity="sha384-rHyoN1iRsVXV4nD0JutlnGaslCJuC7uwjduW9SVrLvRYooPp2bWYgmgJQIXwl/Sp" crossorigin="anonymous">
		
		<!-- 最新的 Bootstrap 核心 JavaScript 文件 -->
		<script src="https://cdn.bootcss.com/bootstrap/3.3.7/js/bootstrap.min.js" integrity="sha384-Tc5IQib027qvyjSMfHjOMaLkfuWVxZxUPnCJA7l2mCWNIpG9mGCD8wGNIcPD7Txa" crossorigin="anonymous"></script>
<link rel="stylesheet" href="css/index.css"/>
<link rel="stylesheet" href="css/style.css"/>
<script type="text/javascript" src="js/jquery1.42.min.js"></script>
<script type="text/javascript" src="js/jquery.SuperSlide.2.1.1.js"></script>
<!--[if lt IE 9]>
<script src="js/html5.js"></script>
<![endif]-->
</head>

<body>

      <!--header start-->
			<div id="header">
		<br>	
		<h1 style="display:inline">WYZ的博客主页</h1>		
			<?php 
				session_start();
				if (isset($_COOKIE['usrname'])) {
					# 若记住了用户信息,则直接传给Session
					$_SESSION['usrname'] = $_COOKIE['usrname'];
					$_SESSION['islogin'] = 1;
				}
				if (isset($_SESSION['islogin'])) {
					//已经登录			
					echo "&nbsp;&nbsp;";
					echo "当前用户为:<a href='content_rw.php?id=".$_SESSION['usrname']." '>".$_SESSION['usrname']."</a>";
					echo "&nbsp;/&nbsp;";
					echo "<a href='logout.php'>注销</a>";
				} 
				else {
					echo "&nbsp;&nbsp;";		
					echo "<a href='signin.php'>注册</a>";
					echo "&nbsp;/&nbsp;";
					echo "<a href='login.php'>登录</a>";			
				}
				echo "&nbsp;&nbsp;";		
				echo "<a href='all_usr.php'>所有用户</a>"

			?>

		</div>
     <!--header end-->
    <!--nav-->
		<div id="nav">
			<ul>
				<li>
					<a href="index.php">首页</a>
				</li>
				<li>
					<a href="about.php">关于站长</a>
				</li>
				<li>
					<a href="reference.php">技术文章</a>
				</li>

				<li>
					<a href="journal.php">个人日记</a>
				</li>

				<li>
					<a href="contact.php">联系站长</a>
				</li>
				<div class="clear"></div>
			</ul>
		</div>

       <!--nav end-->
    <!--content start-->
    <div id="content">
       <!--left-->
         <div class="left" id="about_me">
           <div class="weizi">
           <div class="wz_text">当前位置：<a href="index.php">首页</a> > <h1>关于站长</h1></div>
           </div>
           <div class="about_content">
             
             	<table class="table table-striped">

             	
		<?php
		        while($record=$table->fetch_assoc()){

		        if($_SESSION['usrname']==$record['usrname']){
		            echo "
             		<tr>
             			<td><a href='content_rw.php?id=".$record['usrname']." '>".$record['usrname']."</a></td>
             		</tr>
             		 ";

		        }

		        else echo "
             		<tr>
             			<td><a href='content_r.php?id=".$record['usrname']." '>".$record['usrname']."</a></td>
             		</tr>
             		 ";
		        
		        
		} 
		?>




      
             	</table>
      
			   <hr/><br>

           </div>
         </div>
         <!--end left -->
         <!--right-->
          <div class="right" id="c_right">
          <div class="s_about">
          <h2>关于站长</h2>
           <img src="img/me.jpg" width="230" height="230" alt="站长"/>
           <p>站长：WYZ</p>
           <p>学校：ECNU</p>
           <p>简介：</p>
           

						<div class="clear"></div>
						
					
          </div>

		<!--栏目分类-->
		<div class="lanmubox">
          <div class="hd">
               <ul><li>精心推荐</li><li>最新文章</li><li class="hd_3">随机文章</li></ul>
				<!-- 开始推荐 -->
				</div>
					<div class="bd">
						<ul>
							<li><a href="https://www.baidu.com" target="_blank" title="undefine"> 待定</a></li>
						</ul>	

						<ul>
							<li><a href="https://www.baidu.com" target="_blank" title="undefine"> 待定</a></li>
						</ul>
						
						<ul>
							<li><a href="https://www.baidu.com" target="_blank" title="undefine"> 待定</a></li>
						</ul>
						
					</div>
				</div>
				<!-- 结束推荐-->

				<!-- 开始友情链接 -->
				<div class="link">
					<h2>友情链接</h2>
					<p>
						<a href="http://www.w3school.com.cn/" target="_blank">W3School</a>&nbsp;&nbsp;
						<a href="https://www.nowcoder.com/" target="_blank">牛客网</a>&nbsp;&nbsp;
						<a href="https://www.csdn.net/" target="_blank">CSDN</a>&nbsp;&nbsp;
						<a href="https://www.cnblogs.com/" target="_blank">博客园</a>&nbsp;&nbsp;
						<a href="https://www.oschina.net/" target="_blank">开源中国</a>&nbsp;&nbsp;	
					</p>
				</div>
				<!-- 结束友情链接 -->
					 
           </div>
			
		 			<div class="clear"></div>
         
		</div>
		<!--结束栏目-->

	
		<!--footer start-->
		<div id="footer">
			<p>&reg; WYZ 2019-4-1</p>
			<p>友情链接：
				<a href="http://www.w3school.com.cn/" target="_blank">W3School</a>&nbsp;&nbsp;
				<a href="https://www.nowcoder.com/" target="_blank">牛客网</a>&nbsp;&nbsp;
				<a href="https://www.csdn.net/" target="_blank">CSDN</a>&nbsp;&nbsp;
				<a href="https://www.cnblogs.com/" target="_blank">博客园</a>&nbsp;&nbsp;
				<a href="https://www.oschina.net/" target="_blank">开源中国</a>&nbsp;&nbsp;	
			</p>
		</div>
		<!--footer end-->
		
    <script type="text/javascript">jQuery(".lanmubox").slide({easing:"easeOutBounce",delayTime:400});</script>
    <script  type="text/javascript" src="js/nav.js"></script>
</body>
</html>
